const { io } = require("socket.io-client");
const socket = io("ws://127.0.0.1:1234");

socket.on("connect", () => {
    console.log(socket.id); // x8WIv7-mJelg7on_ALbx
});